import Vue from 'vue'
import App from './App'

import store from './store/index.js'
//把vuex定义成全局组件
Vue.prototype.$store = store

import native from "./static/js/native.js"

import utils from "./utils/utils.js"
import {getDicts, selectDictLabel} from "./utils/dict.js"

Vue.prototype.utils = utils
Vue.prototype.getDicts = getDicts
Vue.prototype.selectDictLabel = selectDictLabel

// import vConsole from "./utils/vConsole.js";
// Vue.use(vConsole)

import fireAlarm from './components/fireAlarm/index';
Vue.use(fireAlarm);

import message from './components/message/index';
Vue.use(message);

import wbmessage from './components/wbmessage/index';
Vue.use(wbmessage);

import noticemessage from './components/noticemessage/index';
Vue.use(noticemessage);

Vue.config.productionTip = false

window.native = native

import * as filters from './utils/filter.js'

Object.keys(filters).forEach(key => {
  Vue.filter(key, filters[key])
})

import BaiduMap from 'vue-baidu-map'

Vue.use(BaiduMap, {
  // ak 是在百度地图开发者平台申请的密钥 详见 http://lbsyun.baidu.com/apiconsole/key */
  ak: 'ZSRUISx1teltvqZBo6Y847xeMTc3XkKW'
})


// main.js
import uView from "uview-ui";
Vue.use(uView);

App.mpType = 'app'

const app = new Vue({
    ...App
})
app.$mount()
